import { createRouter, createWebHashHistory } from 'vue-router'
import AdminLayout from '../layout/adminlayout.vue'
import AuthLayout from '../layout/authlayout.vue'

import Notice from '../views/notice/index.vue'
import History from '../views/history/index.vue'
const routes = [
    {
        path: "/",
        redirect: "auth",
        children: [
            {
                path: 'admin',
                component: AdminLayout,
                children: [
                    {
                        path: "notice/index",
                        name: "notice",
                        component: Notice
                    },
                    {
                        path: "history/index",
                        name: "history",
                        component: History
                    }
                ]
            },
            { path: 'auth', component: AuthLayout },
        ]
    }

]


export default createRouter({
    history: createWebHashHistory(),
    routes,
})
